package practise.inherit;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
import java.util.LinkedHashMap;

public class Test {

	/**
	 * @param args
	 */
	public static void main(String[] args) {
        ArrayList arrayList;
        LinkedHashMap linkedHashMap;
        HashMap hashMap;
        String s ="";
        HashSet hashSet;
        StringBuilder stringBuilder = new StringBuilder("");

        long now = System.currentTimeMillis();

        now = System.currentTimeMillis();
        for(int i=0; i <100000; i ++){
            stringBuilder.append("1");
        }
        System.out.println("time:"+(System.currentTimeMillis()-now));

        now = System.currentTimeMillis();
        for(int i=0; i <100000; i ++){
             s=s+"1";
        }
        System.out.println("time:"+(System.currentTimeMillis()-now));
        now = System.currentTimeMillis();
        for(int i=0; i <100000; i ++){
            s.concat("1");
        }
        System.out.println("time:"+(System.currentTimeMillis()-now));



        short v1 = 18;
        short v5 = 18;
        long v6 = 18;
        Long v2 = new Long("18");
        Long v3 = new Long(18);
        Short v4 = new Short(v1);
        System.out.print(v6 == v1);
        System.out.print(v5 == v1);
        System.out.print(v5 == v2);
        System.out.print(v2 == v3);
        System.out.print(v3.equals(v1));
        System.out.print(v3.equals(v4));
        // TODO Auto-generated method stub
		System.out.println("------- new Children ------");
		new Children();
		System.out.println("------- new Children with param ------");
		new Children("param1 ");
		System.out.println("------- new Static test ------");
		StaticTest testStatic;
		System.out.println("------- new Parent by children ------");
		Parent p = new Children();
		System.out.println("------- get symbol from Parent by children ------");
		p.getSymbol();
		System.out.println("------- get symbol from Parent override method by children ------");
		p.OverrideGetSymbol();
		//p.childMethod(); error
		System.out.println("------- new children ------");
		Children c = new Children();
		System.out.println("------- get symbol from Parent method  ------");
		c.getSymbol();
		System.out.println("------- get symbol from Parent override method  ------");
		c.OverrideGetSymbol();
		
		
	}

}
